<h1 class="page-header">
    <small>开卡赠礼</small>
</h1>
<hr/>
<div class="panel panel-inverse" data-sortable-id="form-stuff-5">
    <div class="panel-heading">
        <h4 class="panel-title">查询</h4>
    </div>
    <div class="panel-body">
        <form id="openGiftForm" name="openGiftForm" method="post" class="form-inline">
            <div class="form-group m-r-10">
                <input type="text" class="form-control" name="EQ_couponId" value="${EQ_couponId}" placeholder="卡券ID">
            </div>
            <div class="form-group m-r-10">
                <input type="text" class="form-control" name="EQ_gradeId" value="${EQ_gradeId}" placeholder="会员等级">
            </div>
            <button type="button" class="btn btn-sm btn-success" onclick="postDataByForm('backend/openGift/list','displayArea','openGiftForm')"><i class="fa fa-search"></i>查询</button>
            <button type="button" class="btn btn-sm btn-danger" onclick="getData('${rc.contextPath}/backend/openGift/add','displayArea')"><i class="fa fa-plus"></i>新增</button>
        </form>
    </div>
</div>
<hr/>
<div class="panel panel-inverse" data-sortable-id="table-basic-4">
    <div class="panel-heading">
        <h4 class="panel-title">开卡赠礼列表</h4>
    </div>
    <div class="panel-body">
        <table class="table table-stred table-bordered">
            <thead>
            <tr>
                <th>ID</th>
                <th>会员等级</th>
                <th>赠送卡券</th>
                <th>卡券数量</th>
                <th>赠送积分</th>
                <th>创建时间</th>
                <th>更新时间</th>
                <th>状态</th>
                <th>操作人</th>
                <th>操作</th>
            </tr>
            </thead>
            <tbody>
            <#if paginationResponse?has_content && paginationResponse.content?exists && paginationResponse.content?size gt 0>
                <#list paginationResponse.content as ct>
                    <tr>
                        <td>${ct.id}</td>
                        <td>${ct.gradeInfo.name}</td>
                        <td><#if ct.couponInfo.name>${ct.couponInfo.name}<#else>-</#if></td>
                        <td>${ct.couponNum}</td>
                        <td>${ct.point}</td>
                        <td>${ct.createTime}</td>
                        <td>${ct.updateTime}</td>
                        <td><#if ct.status == "A"><span class="status-active">启用</span><#else><span class="status-disabled">禁用</span></#if></td>
                        <td>${ct.operator}</td>
                        <td>
                            <a class="label label-success small-btn" href="javascript:getData('${rc.contextPath}/backend/openGift/edit/${ct.id}','displayArea');" title="编辑"><i class="fa fa-edit"></i>编辑</a>
                        </td>
                    </tr>
                </#list>
            <#else>
            <tr class="gradeA even" role="row">
                <td colspan="10" class="text-center">没有符合条件的数据！</td>
            </tr>
            </#if>
        </table>
    </div>
</div>

<!-- 分页组件 -->
<!-- recordBean 分页查询结果Bean
     action 分页请求URL
     formName 分页需要的查询参数的表单名称 -->
<@sp.pagination recordBean=paginationResponse action="${rc.contextPath}/backend/openGift/list" formName="openGiftForm"/>